package top.kangshuai.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import top.kangshuai.model.IndexModel;
import top.kangshuai.service.IndexService;
import top.kangshuai.utils.JsonMessage;

/**
 * -首页
 * 
 * @author DarkKnight
 *
 */
@RestController
public class IndexController {
  @Autowired
  private IndexService indexService;

  @RequestMapping("")
  public JsonMessage index(IndexModel model) throws Exception {
    // {"echo"="abc-123"}
    return indexService.index(model);
  }
}
